diff --git a/drivers/gpio/altera_pio.c b/drivers/gpio/altera_pio.c
index cf0785a..f4e18e1 100644
--- a/drivers/gpio/altera_pio.c
+++ b/drivers/gpio/altera_pio.c
@@ -117,6 +117,6 @@
 	.of_match	= altera_pio_ids,
 	.ops		= &altera_pio_ops,
 	.ofdata_to_platdata = altera_pio_ofdata_to_platdata,
-	.platdata_auto	= sizeof(struct altera_pio_platdata),
+	.plat_auto	= sizeof(struct altera_pio_platdata),
 	.probe		= altera_pio_probe,
 };
diff --git a/drivers/gpio/at91_gpio.c b/drivers/gpio/at91_gpio.c
index 90e692c..4b25af7 100644
--- a/drivers/gpio/at91_gpio.c
+++ b/drivers/gpio/at91_gpio.c
@@ -629,7 +629,7 @@
 	.id	= UCLASS_GPIO,
 #if CONFIG_IS_ENABLED(OF_CONTROL)
 	.of_match = at91_gpio_ids,
-	.platdata_auto	= sizeof(struct at91_port_platdata),
+	.plat_auto	= sizeof(struct at91_port_platdata),
 #endif
 	.ops	= &gpio_at91_ops,
 	.probe	= at91_gpio_probe,
diff --git a/drivers/gpio/atmel_pio4.c b/drivers/gpio/atmel_pio4.c
index d92c061..7a221b4 100644
--- a/drivers/gpio/atmel_pio4.c
+++ b/drivers/gpio/atmel_pio4.c
@@ -338,7 +338,7 @@
 	.probe	= atmel_pio4_probe,
 	.bind	= atmel_pio4_bind,
 	.of_match = atmel_pio4_ids,
-	.platdata_auto	= sizeof(struct atmel_pio4_platdata),
+	.plat_auto	= sizeof(struct atmel_pio4_platdata),
 };
 
 #endif
diff --git a/drivers/gpio/bcm2835_gpio.c b/drivers/gpio/bcm2835_gpio.c
index db349cf..e80830c 100644
--- a/drivers/gpio/bcm2835_gpio.c
+++ b/drivers/gpio/bcm2835_gpio.c
@@ -134,7 +134,7 @@
 	.name	= "gpio_bcm2835",
 	.id	= UCLASS_GPIO,
 	.ofdata_to_platdata = of_match_ptr(bcm2835_gpio_ofdata_to_platdata),
-	.platdata_auto	= sizeof(struct bcm2835_gpio_platdata),
+	.plat_auto	= sizeof(struct bcm2835_gpio_platdata),
 	.ops	= &gpio_bcm2835_ops,
 	.probe	= bcm2835_gpio_probe,
 	.flags	= DM_FLAG_PRE_RELOC,
diff --git a/drivers/gpio/da8xx_gpio.c b/drivers/gpio/da8xx_gpio.c
index 507f8b1..c8b12ac 100644
--- a/drivers/gpio/da8xx_gpio.c
+++ b/drivers/gpio/da8xx_gpio.c
@@ -560,7 +560,7 @@
 	.ofdata_to_platdata = of_match_ptr(davinci_gpio_ofdata_to_platdata),
 	.of_match = davinci_gpio_ids,
 	.bind   = dm_scan_fdt_dev,
-	.platdata_auto	= sizeof(struct davinci_gpio_platdata),
+	.plat_auto	= sizeof(struct davinci_gpio_platdata),
 	.probe	= davinci_gpio_probe,
 	.priv_auto	= sizeof(struct davinci_gpio_bank),
 };
diff --git a/drivers/gpio/dwapb_gpio.c b/drivers/gpio/dwapb_gpio.c
index 3a86884..6639e2e 100644
--- a/drivers/gpio/dwapb_gpio.c
+++ b/drivers/gpio/dwapb_gpio.c
@@ -141,7 +141,7 @@
 static int gpio_dwapb_probe(struct udevice *dev)
 {
 	struct gpio_dev_priv *priv = dev_get_uclass_priv(dev);
-	struct gpio_dwapb_platdata *plat = dev->platdata;
+	struct gpio_dwapb_platdata *plat = dev->plat;
 
 	if (!plat) {
 		/* Reset on parent device only */
diff --git a/drivers/gpio/gpio-uclass.c b/drivers/gpio/gpio-uclass.c
index fb9393d..fdb3a45 100644
--- a/drivers/gpio/gpio-uclass.c
+++ b/drivers/gpio/gpio-uclass.c
@@ -341,7 +341,7 @@
 	.ofdata_to_platdata = gpio_hog_ofdata_to_platdata,
 	.probe = gpio_hog_probe,
 	.priv_auto	= sizeof(struct gpio_hog_priv),
-	.platdata_auto	= sizeof(struct gpio_hog_data),
+	.plat_auto	= sizeof(struct gpio_hog_data),
 };
 #else
 int gpio_hog_lookup_name(const char *name, struct gpio_desc **desc)
diff --git a/drivers/gpio/hsdk-creg-gpio.c b/drivers/gpio/hsdk-creg-gpio.c
index d40365e..66f8441 100644
--- a/drivers/gpio/hsdk-creg-gpio.c
+++ b/drivers/gpio/hsdk-creg-gpio.c
@@ -165,5 +165,5 @@
 	.ops	= &hsdk_creg_gpio_ops,
 	.probe	= hsdk_creg_gpio_probe,
 	.of_match = hsdk_creg_gpio_ids,
-	.platdata_auto	= sizeof(struct hsdk_creg_gpio),
+	.plat_auto	= sizeof(struct hsdk_creg_gpio),
 };
diff --git a/drivers/gpio/imx_rgpio2p.c b/drivers/gpio/imx_rgpio2p.c
index 2a09975..80e934e 100644
--- a/drivers/gpio/imx_rgpio2p.c
+++ b/drivers/gpio/imx_rgpio2p.c
@@ -151,12 +151,12 @@
 
 static int imx_rgpio2p_bind(struct udevice *dev)
 {
-	struct imx_rgpio2p_plat *plat = dev->platdata;
+	struct imx_rgpio2p_plat *plat = dev->plat;
 	fdt_addr_t addr;
 
 	/*
-	 * If platdata already exsits, directly return.
-	 * Actually only when DT is not supported, platdata
+	 * If plat already exsits, directly return.
+	 * Actually only when DT is not supported, plat
 	 * is statically initialized in U_BOOT_DEVICES.Here
 	 * will return.
 	 */
@@ -171,7 +171,7 @@
 	 * TODO:
 	 * When every board is converted to driver model and DT is supported,
 	 * this can be done by auto-alloc feature, but not using calloc
-	 * to alloc memory for platdata.
+	 * to alloc memory for plat.
 	 *
 	 * For example imx_rgpio2p_plat uses platform data rather than device
 	 * tree.
@@ -184,7 +184,7 @@
 
 	plat->regs = (struct gpio_regs *)addr;
 	plat->bank_index = dev->req_seq;
-	dev->platdata = plat;
+	dev->plat = plat;
 
 	return 0;
 }
diff --git a/drivers/gpio/intel_broadwell_gpio.c b/drivers/gpio/intel_broadwell_gpio.c
index cb21740..b05233f 100644
--- a/drivers/gpio/intel_broadwell_gpio.c
+++ b/drivers/gpio/intel_broadwell_gpio.c
@@ -185,5 +185,5 @@
 	.ofdata_to_platdata	= broadwell_gpio_ofdata_to_platdata,
 	.probe	= broadwell_gpio_probe,
 	.priv_auto	= sizeof(struct broadwell_bank_priv),
-	.platdata_auto	= sizeof(struct broadwell_bank_platdata),
+	.plat_auto	= sizeof(struct broadwell_bank_platdata),
 };
diff --git a/drivers/gpio/intel_ich6_gpio.c b/drivers/gpio/intel_ich6_gpio.c
index bba85b3..3fdc981 100644
--- a/drivers/gpio/intel_ich6_gpio.c
+++ b/drivers/gpio/intel_ich6_gpio.c
@@ -237,5 +237,5 @@
 	.ofdata_to_platdata	= gpio_ich6_ofdata_to_platdata,
 	.probe	= ich6_gpio_probe,
 	.priv_auto	= sizeof(struct ich6_bank_priv),
-	.platdata_auto	= sizeof(struct ich6_bank_platdata),
+	.plat_auto	= sizeof(struct ich6_bank_platdata),
 };
diff --git a/drivers/gpio/iproc_gpio.c b/drivers/gpio/iproc_gpio.c
index 81eb2e1..73f74ed 100644
--- a/drivers/gpio/iproc_gpio.c
+++ b/drivers/gpio/iproc_gpio.c
@@ -286,5 +286,5 @@
 	.of_match		= iproc_gpio_ids,
 	.ops			= &iproc_gpio_ops,
 	.ofdata_to_platdata	= iproc_gpio_ofdata_to_platdata,
-	.platdata_auto	= sizeof(struct iproc_gpio_platdata),
+	.plat_auto	= sizeof(struct iproc_gpio_platdata),
 };
diff --git a/drivers/gpio/mpc83xx_spisel_boot.c b/drivers/gpio/mpc83xx_spisel_boot.c
index 3020cc95..dae94b5 100644
--- a/drivers/gpio/mpc83xx_spisel_boot.c
+++ b/drivers/gpio/mpc83xx_spisel_boot.c
@@ -141,7 +141,7 @@
 	.ops	= &mpc83xx_spisel_boot_ops,
 #if CONFIG_IS_ENABLED(OF_CONTROL)
 	.ofdata_to_platdata = mpc83xx_spisel_boot_ofdata_to_platdata,
-	.platdata_auto	= sizeof(struct mpc8xxx_gpio_plat),
+	.plat_auto	= sizeof(struct mpc8xxx_gpio_plat),
 	.of_match = mpc83xx_spisel_boot_ids,
 #endif
 	.probe	= mpc83xx_spisel_boot_probe,
diff --git a/drivers/gpio/mpc8xxx_gpio.c b/drivers/gpio/mpc8xxx_gpio.c
index fa08909..6b64fc0 100644
--- a/drivers/gpio/mpc8xxx_gpio.c
+++ b/drivers/gpio/mpc8xxx_gpio.c
@@ -295,7 +295,7 @@
 	.ops	= &gpio_mpc8xxx_ops,
 #if CONFIG_IS_ENABLED(OF_CONTROL)
 	.ofdata_to_platdata = mpc8xxx_gpio_ofdata_to_platdata,
-	.platdata_auto	= sizeof(struct mpc8xxx_gpio_plat),
+	.plat_auto	= sizeof(struct mpc8xxx_gpio_plat),
 	.of_match = mpc8xxx_gpio_ids,
 #endif
 	.probe	= mpc8xxx_gpio_probe,
diff --git a/drivers/gpio/mt7621_gpio.c b/drivers/gpio/mt7621_gpio.c
index ea51291..3a06d17 100644
--- a/drivers/gpio/mt7621_gpio.c
+++ b/drivers/gpio/mt7621_gpio.c
@@ -130,7 +130,7 @@
  */
 static int gpio_mediatek_bind(struct udevice *parent)
 {
-	struct mediatek_gpio_platdata *plat = parent->platdata;
+	struct mediatek_gpio_platdata *plat = parent->plat;
 	ofnode node;
 	int bank = 0;
 	int ret;
diff --git a/drivers/gpio/mxc_gpio.c b/drivers/gpio/mxc_gpio.c
index 4881032..55fadad 100644
--- a/drivers/gpio/mxc_gpio.c
+++ b/drivers/gpio/mxc_gpio.c
@@ -339,7 +339,7 @@
 	.ops	= &gpio_mxc_ops,
 	.probe	= mxc_gpio_probe,
 	.ofdata_to_platdata = mxc_gpio_ofdata_to_platdata,
-	.platdata_auto	= sizeof(struct mxc_gpio_plat),
+	.plat_auto	= sizeof(struct mxc_gpio_plat),
 	.priv_auto	= sizeof(struct mxc_bank_info),
 	.of_match = mxc_gpio_ids,
 	.bind	= mxc_gpio_bind,
diff --git a/drivers/gpio/mxs_gpio.c b/drivers/gpio/mxs_gpio.c
index 83147b4..581d161 100644
--- a/drivers/gpio/mxs_gpio.c
+++ b/drivers/gpio/mxs_gpio.c
@@ -264,7 +264,7 @@
 #if CONFIG_IS_ENABLED(OF_CONTROL) && !CONFIG_IS_ENABLED(OF_PLATDATA)
 static int mxs_ofdata_to_platdata(struct udevice *dev)
 {
-	struct mxs_gpio_platdata *plat = dev->platdata;
+	struct mxs_gpio_platdata *plat = dev->plat;
 	struct fdtdec_phandle_args args;
 	int node = dev_of_offset(dev);
 	int ret;
@@ -299,7 +299,7 @@
 	.ops	= &gpio_mxs_ops,
 	.probe	= mxs_gpio_probe,
 	.priv_auto	= sizeof(struct mxs_gpio_priv),
-	.platdata_auto	= sizeof(struct mxs_gpio_platdata),
+	.plat_auto	= sizeof(struct mxs_gpio_platdata),
 #if CONFIG_IS_ENABLED(OF_CONTROL) && !CONFIG_IS_ENABLED(OF_PLATDATA)
 	.of_match = mxs_gpio_ids,
 	.ofdata_to_platdata = mxs_ofdata_to_platdata,
diff --git a/drivers/gpio/nx_gpio.c b/drivers/gpio/nx_gpio.c
index 1bd12f1..f0bbb9e 100644
--- a/drivers/gpio/nx_gpio.c
+++ b/drivers/gpio/nx_gpio.c
@@ -245,6 +245,6 @@
 	.of_match	= nx_gpio_ids,
 	.ops		= &nx_gpio_ops,
 	.ofdata_to_platdata = nx_gpio_ofdata_to_platdata,
-	.platdata_auto	= sizeof(struct nx_gpio_platdata),
+	.plat_auto	= sizeof(struct nx_gpio_platdata),
 	.probe		= nx_gpio_probe,
 };
diff --git a/drivers/gpio/omap_gpio.c b/drivers/gpio/omap_gpio.c
index 9e82805..7be1beb 100644
--- a/drivers/gpio/omap_gpio.c
+++ b/drivers/gpio/omap_gpio.c
@@ -316,7 +316,7 @@
 	* TODO:
 	* When every board is converted to driver model and DT is
 	* supported, this can be done by auto-alloc feature, but
-	* not using calloc to alloc memory for platdata.
+	* not using calloc to alloc memory for plat.
 	*
 	* For example am33xx_gpio uses platform data rather than device tree.
 	*
@@ -328,7 +328,7 @@
 
 	plat->base = base_addr;
 	plat->port_name = fdt_get_name(gd->fdt_blob, dev_of_offset(dev), NULL);
-	dev->platdata = plat;
+	dev->plat = plat;
 
 	return 0;
 }
@@ -363,7 +363,7 @@
 #if !CONFIG_IS_ENABLED(OF_PLATDATA)
 	.of_match = omap_gpio_ids,
 	.ofdata_to_platdata = of_match_ptr(omap_gpio_ofdata_to_platdata),
-	.platdata_auto	= sizeof(struct omap_gpio_platdata),
+	.plat_auto	= sizeof(struct omap_gpio_platdata),
 #endif
 #else
 	.bind   = omap_gpio_bind,
diff --git a/drivers/gpio/pca953x_gpio.c b/drivers/gpio/pca953x_gpio.c
index 32d4a83..239c0f7 100644
--- a/drivers/gpio/pca953x_gpio.c
+++ b/drivers/gpio/pca953x_gpio.c
@@ -385,6 +385,6 @@
 	.id		= UCLASS_GPIO,
 	.ops		= &pca953x_ops,
 	.probe		= pca953x_probe,
-	.platdata_auto	= sizeof(struct pca953x_info),
+	.plat_auto	= sizeof(struct pca953x_info),
 	.of_match	= pca953x_ids,
 };
diff --git a/drivers/gpio/pcf8575_gpio.c b/drivers/gpio/pcf8575_gpio.c
index 7fcadc7..d0ff881 100644
--- a/drivers/gpio/pcf8575_gpio.c
+++ b/drivers/gpio/pcf8575_gpio.c
@@ -55,7 +55,7 @@
 
 static int pcf8575_i2c_write_le16(struct udevice *dev, unsigned int word)
 {
-	struct dm_i2c_chip *chip = dev_get_parent_platdata(dev);
+	struct dm_i2c_chip *chip = dev_get_parent_plat(dev);
 	u8 buf[2] = { word & 0xff, word >> 8, };
 	int ret;
 
@@ -69,7 +69,7 @@
 
 static int pcf8575_i2c_read_le16(struct udevice *dev)
 {
-	struct dm_i2c_chip *chip = dev_get_parent_platdata(dev);
+	struct dm_i2c_chip *chip = dev_get_parent_plat(dev);
 	u8 buf[2];
 	int ret;
 
@@ -177,5 +177,5 @@
 	.of_match = pcf8575_gpio_ids,
 	.ofdata_to_platdata = pcf8575_ofdata_platdata,
 	.probe	= pcf8575_gpio_probe,
-	.platdata_auto	= sizeof(struct pcf8575_chip),
+	.plat_auto	= sizeof(struct pcf8575_chip),
 };
diff --git a/drivers/gpio/s5p_gpio.c b/drivers/gpio/s5p_gpio.c
index 3fc4367..6202e48 100644
--- a/drivers/gpio/s5p_gpio.c
+++ b/drivers/gpio/s5p_gpio.c
@@ -287,7 +287,7 @@
 {
 	struct gpio_dev_priv *uc_priv = dev_get_uclass_priv(dev);
 	struct exynos_bank_info *priv = dev->priv;
-	struct exynos_gpio_platdata *plat = dev->platdata;
+	struct exynos_gpio_platdata *plat = dev->plat;
 
 	/* Only child devices have ports */
 	if (!plat)
@@ -307,7 +307,7 @@
  */
 static int gpio_exynos_bind(struct udevice *parent)
 {
-	struct exynos_gpio_platdata *plat = parent->platdata;
+	struct exynos_gpio_platdata *plat = parent->plat;
 	struct s5p_gpio_bank *bank, *base;
 	const void *blob = gd->fdt_blob;
 	int node;
diff --git a/drivers/gpio/sifive-gpio.c b/drivers/gpio/sifive-gpio.c
index 19239f5..4be8d4f 100644
--- a/drivers/gpio/sifive-gpio.c
+++ b/drivers/gpio/sifive-gpio.c
@@ -172,7 +172,7 @@
 	.id	= UCLASS_GPIO,
 	.of_match = sifive_gpio_match,
 	.ofdata_to_platdata = of_match_ptr(sifive_gpio_ofdata_to_platdata),
-	.platdata_auto	= sizeof(struct sifive_gpio_platdata),
+	.plat_auto	= sizeof(struct sifive_gpio_platdata),
 	.ops	= &sifive_gpio_ops,
 	.probe	= sifive_gpio_probe,
 };
diff --git a/drivers/gpio/sunxi_gpio.c b/drivers/gpio/sunxi_gpio.c
index dea71a7..62d584a 100644
--- a/drivers/gpio/sunxi_gpio.c
+++ b/drivers/gpio/sunxi_gpio.c
@@ -285,7 +285,7 @@
 {
 	struct sunxi_gpio_soc_data *soc_data =
 		(struct sunxi_gpio_soc_data *)dev_get_driver_data(parent);
-	struct sunxi_gpio_platdata *plat = parent->platdata;
+	struct sunxi_gpio_platdata *plat = parent->plat;
 	struct sunxi_gpio_reg *ctlr;
 	int bank, ret;
 
diff --git a/drivers/gpio/tegra186_gpio.c b/drivers/gpio/tegra186_gpio.c
index ad97e13..14c9d90 100644
--- a/drivers/gpio/tegra186_gpio.c
+++ b/drivers/gpio/tegra186_gpio.c
@@ -34,7 +34,7 @@
 static uint32_t *tegra186_gpio_reg(struct udevice *dev, uint32_t reg,
 				   uint32_t gpio)
 {
-	struct tegra186_gpio_platdata *plat = dev->platdata;
+	struct tegra186_gpio_platdata *plat = dev->plat;
 	uint32_t index = (reg + (gpio * TEGRA186_GPIO_PER_GPIO_STRIDE)) / 4;
 
 	return &(plat->regs[index]);
@@ -166,7 +166,7 @@
  */
 static int tegra186_gpio_bind(struct udevice *parent)
 {
-	struct tegra186_gpio_platdata *parent_plat = parent->platdata;
+	struct tegra186_gpio_platdata *parent_plat = parent->plat;
 	struct tegra186_gpio_ctlr_data *ctlr_data =
 		(struct tegra186_gpio_ctlr_data *)dev_get_driver_data(parent);
 	uint32_t *regs;
@@ -201,7 +201,7 @@
 
 static int tegra186_gpio_probe(struct udevice *dev)
 {
-	struct tegra186_gpio_platdata *plat = dev->platdata;
+	struct tegra186_gpio_platdata *plat = dev->plat;
 	struct gpio_dev_priv *uc_priv = dev_get_uclass_priv(dev);
 
 	/* Only child devices have ports */
diff --git a/drivers/gpio/tegra_gpio.c b/drivers/gpio/tegra_gpio.c
index 7583c8d..862a63f 100644
--- a/drivers/gpio/tegra_gpio.c
+++ b/drivers/gpio/tegra_gpio.c
@@ -292,7 +292,7 @@
 {
 	struct gpio_dev_priv *uc_priv = dev_get_uclass_priv(dev);
 	struct tegra_port_info *priv = dev->priv;
-	struct tegra_gpio_platdata *plat = dev->platdata;
+	struct tegra_gpio_platdata *plat = dev->plat;
 
 	/* Only child devices have ports */
 	if (!plat)
@@ -313,7 +313,7 @@
  */
 static int gpio_tegra_bind(struct udevice *parent)
 {
-	struct tegra_gpio_platdata *plat = parent->platdata;
+	struct tegra_gpio_platdata *plat = parent->plat;
 	struct gpio_ctlr *ctlr;
 	int bank_count;
 	int bank;
diff --git a/drivers/gpio/vybrid_gpio.c b/drivers/gpio/vybrid_gpio.c
index 9c4bba8..f55553c 100644
--- a/drivers/gpio/vybrid_gpio.c
+++ b/drivers/gpio/vybrid_gpio.c
@@ -133,5 +133,5 @@
 	.ofdata_to_platdata = vybrid_gpio_odata_to_platdata,
 	.probe	= vybrid_gpio_probe,
 	.priv_auto	= sizeof(struct vybrid_gpios),
-	.platdata_auto	= sizeof(struct vybrid_gpio_platdata),
+	.plat_auto	= sizeof(struct vybrid_gpio_platdata),
 };
diff --git a/drivers/gpio/xilinx_gpio.c b/drivers/gpio/xilinx_gpio.c
index 1bb70b1..6de08e1 100644
--- a/drivers/gpio/xilinx_gpio.c
+++ b/drivers/gpio/xilinx_gpio.c
@@ -36,13 +36,13 @@
 static int xilinx_gpio_get_bank_pin(unsigned offset, u32 *bank_num,
 				    u32 *bank_pin_num, struct udevice *dev)
 {
-	struct xilinx_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct xilinx_gpio_platdata *plat = dev_get_platdata(dev);
 	u32 bank, max_pins;
 	/* the first gpio is 0 not 1 */
 	u32 pin_num = offset;
 
 	for (bank = 0; bank < XILINX_GPIO_MAX_BANK; bank++) {
-		max_pins = platdata->bank_max[bank];
+		max_pins = plat->bank_max[bank];
 		if (pin_num < max_pins) {
 			debug("%s: found at bank 0x%x pin 0x%x\n", __func__,
 			      bank, pin_num);
@@ -59,7 +59,7 @@
 static int xilinx_gpio_set_value(struct udevice *dev, unsigned offset,
 				 int value)
 {
-	struct xilinx_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct xilinx_gpio_platdata *plat = dev_get_platdata(dev);
 	struct xilinx_gpio_privdata *priv = dev_get_priv(dev);
 	int val, ret;
 	u32 bank, pin;
@@ -71,14 +71,14 @@
 	val = priv->output_val[bank];
 
 	debug("%s: regs: %lx, value: %x, gpio: %x, bank %x, pin %x, out %x\n",
-	      __func__, (ulong)platdata->regs, value, offset, bank, pin, val);
+	      __func__, (ulong)plat->regs, value, offset, bank, pin, val);
 
 	if (value)
 		val = val | (1 << pin);
 	else
 		val = val & ~(1 << pin);
 
-	writel(val, &platdata->regs->gpiodata + bank * 2);
+	writel(val, &plat->regs->gpiodata + bank * 2);
 
 	priv->output_val[bank] = val;
 
@@ -87,7 +87,7 @@
 
 static int xilinx_gpio_get_value(struct udevice *dev, unsigned offset)
 {
-	struct xilinx_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct xilinx_gpio_platdata *plat = dev_get_platdata(dev);
 	struct xilinx_gpio_privdata *priv = dev_get_priv(dev);
 	int val, ret;
 	u32 bank, pin;
@@ -97,14 +97,14 @@
 		return ret;
 
 	debug("%s: regs: %lx, gpio: %x, bank %x, pin %x\n", __func__,
-	      (ulong)platdata->regs, offset, bank, pin);
+	      (ulong)plat->regs, offset, bank, pin);
 
-	if (platdata->bank_output[bank]) {
+	if (plat->bank_output[bank]) {
 		debug("%s: Read saved output value\n", __func__);
 		val = priv->output_val[bank];
 	} else {
 		debug("%s: Read input value from reg\n", __func__);
-		val = readl(&platdata->regs->gpiodata + bank * 2);
+		val = readl(&plat->regs->gpiodata + bank * 2);
 	}
 
 	val = !!(val & (1 << pin));
@@ -114,7 +114,7 @@
 
 static int xilinx_gpio_get_function(struct udevice *dev, unsigned offset)
 {
-	struct xilinx_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct xilinx_gpio_platdata *plat = dev_get_platdata(dev);
 	int val, ret;
 	u32 bank, pin;
 
@@ -123,15 +123,15 @@
 		return ret;
 
 	/* Check if all pins are inputs */
-	if (platdata->bank_input[bank])
+	if (plat->bank_input[bank])
 		return GPIOF_INPUT;
 
 	/* Check if all pins are outputs */
-	if (platdata->bank_output[bank])
+	if (plat->bank_output[bank])
 		return GPIOF_OUTPUT;
 
 	/* FIXME test on dual */
-	val = readl(&platdata->regs->gpiodir + bank * 2);
+	val = readl(&plat->regs->gpiodir + bank * 2);
 	val = !(val & (1 << pin));
 
 	/* input is 1 in reg but GPIOF_INPUT is 0 */
@@ -143,7 +143,7 @@
 static int xilinx_gpio_direction_output(struct udevice *dev, unsigned offset,
 					int value)
 {
-	struct xilinx_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct xilinx_gpio_platdata *plat = dev_get_platdata(dev);
 	int val, ret;
 	u32 bank, pin;
 
@@ -152,15 +152,15 @@
 		return ret;
 
 	/* can't change it if all is input by default */
-	if (platdata->bank_input[bank])
+	if (plat->bank_input[bank])
 		return -EINVAL;
 
 	xilinx_gpio_set_value(dev, offset, value);
 
-	if (!platdata->bank_output[bank]) {
-		val = readl(&platdata->regs->gpiodir + bank * 2);
+	if (!plat->bank_output[bank]) {
+		val = readl(&plat->regs->gpiodir + bank * 2);
 		val = val & ~(1 << pin);
-		writel(val, &platdata->regs->gpiodir + bank * 2);
+		writel(val, &plat->regs->gpiodir + bank * 2);
 	}
 
 	return 0;
@@ -168,7 +168,7 @@
 
 static int xilinx_gpio_direction_input(struct udevice *dev, unsigned offset)
 {
-	struct xilinx_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct xilinx_gpio_platdata *plat = dev_get_platdata(dev);
 	int val, ret;
 	u32 bank, pin;
 
@@ -177,16 +177,16 @@
 		return ret;
 
 	/* Already input */
-	if (platdata->bank_input[bank])
+	if (plat->bank_input[bank])
 		return 0;
 
 	/* can't change it if all is output by default */
-	if (platdata->bank_output[bank])
+	if (plat->bank_output[bank])
 		return -EINVAL;
 
-	val = readl(&platdata->regs->gpiodir + bank * 2);
+	val = readl(&plat->regs->gpiodir + bank * 2);
 	val = val | (1 << pin);
-	writel(val, &platdata->regs->gpiodir + bank * 2);
+	writel(val, &plat->regs->gpiodir + bank * 2);
 
 	return 0;
 }
@@ -194,7 +194,7 @@
 static int xilinx_gpio_xlate(struct udevice *dev, struct gpio_desc *desc,
 			     struct ofnode_phandle_args *args)
 {
-	struct xilinx_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct xilinx_gpio_platdata *plat = dev_get_platdata(dev);
 
 	desc->offset = args->args[0];
 
@@ -209,13 +209,13 @@
 	 * add amount of pins in second channel if present.
 	 */
 	if (args->args[1]) {
-		if (!platdata->bank_max[1]) {
+		if (!plat->bank_max[1]) {
 			printf("%s: %s has no second channel\n",
 			       __func__, dev->name);
 			return -EINVAL;
 		}
 
-		desc->offset += platdata->bank_max[0];
+		desc->offset += plat->bank_max[0];
 	}
 
 	/* The third cell is optional */
@@ -239,7 +239,7 @@
 
 static int xilinx_gpio_probe(struct udevice *dev)
 {
-	struct xilinx_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct xilinx_gpio_platdata *plat = dev_get_platdata(dev);
 	struct xilinx_gpio_privdata *priv = dev_get_priv(dev);
 	struct gpio_dev_priv *uc_priv = dev_get_uclass_priv(dev);
 	const void *label_ptr;
@@ -253,42 +253,38 @@
 		uc_priv->bank_name = dev->name;
 	}
 
-	uc_priv->gpio_count = platdata->bank_max[0] + platdata->bank_max[1];
+	uc_priv->gpio_count = plat->bank_max[0] + plat->bank_max[1];
 
-	priv->output_val[0] = platdata->dout_default[0];
+	priv->output_val[0] = plat->dout_default[0];
 
-	if (platdata->bank_max[1])
-		priv->output_val[1] = platdata->dout_default[1];
+	if (plat->bank_max[1])
+		priv->output_val[1] = plat->dout_default[1];
 
 	return 0;
 }
 
 static int xilinx_gpio_ofdata_to_platdata(struct udevice *dev)
 {
-	struct xilinx_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct xilinx_gpio_platdata *plat = dev_get_platdata(dev);
 	int is_dual;
 
-	platdata->regs = (struct gpio_regs *)dev_read_addr(dev);
+	plat->regs = (struct gpio_regs *)dev_read_addr(dev);
 
-	platdata->bank_max[0] = dev_read_u32_default(dev,
-						     "xlnx,gpio-width", 0);
-	platdata->bank_input[0] = dev_read_u32_default(dev,
-						       "xlnx,all-inputs", 0);
-	platdata->bank_output[0] = dev_read_u32_default(dev,
-							"xlnx,all-outputs", 0);
-	platdata->dout_default[0] = dev_read_u32_default(dev,
-							 "xlnx,dout-default",
-							 0);
+	plat->bank_max[0] = dev_read_u32_default(dev, "xlnx,gpio-width", 0);
+	plat->bank_input[0] = dev_read_u32_default(dev, "xlnx,all-inputs", 0);
+	plat->bank_output[0] = dev_read_u32_default(dev, "xlnx,all-outputs", 0);
+	plat->dout_default[0] = dev_read_u32_default(dev, "xlnx,dout-default",
+						     0);
 
 	is_dual = dev_read_u32_default(dev, "xlnx,is-dual", 0);
 	if (is_dual) {
-		platdata->bank_max[1] = dev_read_u32_default(dev,
-						"xlnx,gpio2-width", 0);
-		platdata->bank_input[1] = dev_read_u32_default(dev,
+		plat->bank_max[1] = dev_read_u32_default(dev,
+							 "xlnx,gpio2-width", 0);
+		plat->bank_input[1] = dev_read_u32_default(dev,
 						"xlnx,all-inputs-2", 0);
-		platdata->bank_output[1] = dev_read_u32_default(dev,
+		plat->bank_output[1] = dev_read_u32_default(dev,
 						"xlnx,all-outputs-2", 0);
-		platdata->dout_default[1] = dev_read_u32_default(dev,
+		plat->dout_default[1] = dev_read_u32_default(dev,
 						"xlnx,dout-default-2", 0);
 	}
 
@@ -307,6 +303,6 @@
 	.of_match = xilinx_gpio_ids,
 	.ofdata_to_platdata = xilinx_gpio_ofdata_to_platdata,
 	.probe = xilinx_gpio_probe,
-	.platdata_auto	= sizeof(struct xilinx_gpio_platdata),
+	.plat_auto	= sizeof(struct xilinx_gpio_platdata),
 	.priv_auto	= sizeof(struct xilinx_gpio_privdata),
 };
diff --git a/drivers/gpio/zynq_gpio.c b/drivers/gpio/zynq_gpio.c
index 4ef2985..cfe3567 100644
--- a/drivers/gpio/zynq_gpio.c
+++ b/drivers/gpio/zynq_gpio.c
@@ -193,20 +193,20 @@
 					  unsigned int *bank_pin_num,
 					  struct udevice *dev)
 {
-	struct zynq_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct zynq_gpio_platdata *plat = dev_get_platdata(dev);
 	u32 bank;
 
-	for (bank = 0; bank < platdata->p_data->max_bank; bank++) {
-		if (pin_num >= platdata->p_data->bank_min[bank] &&
-		    pin_num <= platdata->p_data->bank_max[bank]) {
+	for (bank = 0; bank < plat->p_data->max_bank; bank++) {
+		if (pin_num >= plat->p_data->bank_min[bank] &&
+		    pin_num <= plat->p_data->bank_max[bank]) {
 			*bank_num = bank;
 			*bank_pin_num = pin_num -
-					platdata->p_data->bank_min[bank];
+					plat->p_data->bank_min[bank];
 			return;
 		}
 	}
 
-	if (bank >= platdata->p_data->max_bank) {
+	if (bank >= plat->p_data->max_bank) {
 		printf("Invalid bank and pin num\n");
 		*bank_num = 0;
 		*bank_pin_num = 0;
@@ -215,9 +215,9 @@
 
 static int gpio_is_valid(unsigned gpio, struct udevice *dev)
 {
-	struct zynq_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct zynq_gpio_platdata *plat = dev_get_platdata(dev);
 
-	return gpio < platdata->p_data->ngpio;
+	return gpio < plat->p_data->ngpio;
 }
 
 static int check_gpio(unsigned gpio, struct udevice *dev)
@@ -233,14 +233,14 @@
 {
 	u32 data;
 	unsigned int bank_num, bank_pin_num;
-	struct zynq_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct zynq_gpio_platdata *plat = dev_get_platdata(dev);
 
 	if (check_gpio(gpio, dev) < 0)
 		return -1;
 
 	zynq_gpio_get_bank_pin(gpio, &bank_num, &bank_pin_num, dev);
 
-	data = readl(platdata->base +
+	data = readl(plat->base +
 			     ZYNQ_GPIO_DATA_RO_OFFSET(bank_num));
 
 	return (data >> bank_pin_num) & 1;
@@ -249,7 +249,7 @@
 static int zynq_gpio_set_value(struct udevice *dev, unsigned gpio, int value)
 {
 	unsigned int reg_offset, bank_num, bank_pin_num;
-	struct zynq_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct zynq_gpio_platdata *plat = dev_get_platdata(dev);
 
 	if (check_gpio(gpio, dev) < 0)
 		return -1;
@@ -272,7 +272,7 @@
 	value = ~(1 << (bank_pin_num + ZYNQ_GPIO_MID_PIN_NUM)) &
 		((value << bank_pin_num) | ZYNQ_GPIO_UPPER_MASK);
 
-	writel(value, platdata->base + reg_offset);
+	writel(value, plat->base + reg_offset);
 
 	return 0;
 }
@@ -281,7 +281,7 @@
 {
 	u32 reg;
 	unsigned int bank_num, bank_pin_num;
-	struct zynq_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct zynq_gpio_platdata *plat = dev_get_platdata(dev);
 
 	if (check_gpio(gpio, dev) < 0)
 		return -1;
@@ -293,9 +293,9 @@
 		return -1;
 
 	/* clear the bit in direction mode reg to set the pin as input */
-	reg = readl(platdata->base + ZYNQ_GPIO_DIRM_OFFSET(bank_num));
+	reg = readl(plat->base + ZYNQ_GPIO_DIRM_OFFSET(bank_num));
 	reg &= ~BIT(bank_pin_num);
-	writel(reg, platdata->base + ZYNQ_GPIO_DIRM_OFFSET(bank_num));
+	writel(reg, plat->base + ZYNQ_GPIO_DIRM_OFFSET(bank_num));
 
 	return 0;
 }
@@ -305,7 +305,7 @@
 {
 	u32 reg;
 	unsigned int bank_num, bank_pin_num;
-	struct zynq_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct zynq_gpio_platdata *plat = dev_get_platdata(dev);
 
 	if (check_gpio(gpio, dev) < 0)
 		return -1;
@@ -313,14 +313,14 @@
 	zynq_gpio_get_bank_pin(gpio, &bank_num, &bank_pin_num, dev);
 
 	/* set the GPIO pin as output */
-	reg = readl(platdata->base + ZYNQ_GPIO_DIRM_OFFSET(bank_num));
+	reg = readl(plat->base + ZYNQ_GPIO_DIRM_OFFSET(bank_num));
 	reg |= BIT(bank_pin_num);
-	writel(reg, platdata->base + ZYNQ_GPIO_DIRM_OFFSET(bank_num));
+	writel(reg, plat->base + ZYNQ_GPIO_DIRM_OFFSET(bank_num));
 
 	/* configure the output enable reg for the pin */
-	reg = readl(platdata->base + ZYNQ_GPIO_OUTEN_OFFSET(bank_num));
+	reg = readl(plat->base + ZYNQ_GPIO_OUTEN_OFFSET(bank_num));
 	reg |= BIT(bank_pin_num);
-	writel(reg, platdata->base + ZYNQ_GPIO_OUTEN_OFFSET(bank_num));
+	writel(reg, plat->base + ZYNQ_GPIO_OUTEN_OFFSET(bank_num));
 
 	/* set the state of the pin */
 	zynq_gpio_set_value(dev, gpio, value);
@@ -331,7 +331,7 @@
 {
 	u32 reg;
 	unsigned int bank_num, bank_pin_num;
-	struct zynq_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct zynq_gpio_platdata *plat = dev_get_platdata(dev);
 
 	if (check_gpio(offset, dev) < 0)
 		return -1;
@@ -339,7 +339,7 @@
 	zynq_gpio_get_bank_pin(offset, &bank_num, &bank_pin_num, dev);
 
 	/* set the GPIO pin as output */
-	reg = readl(platdata->base + ZYNQ_GPIO_DIRM_OFFSET(bank_num));
+	reg = readl(plat->base + ZYNQ_GPIO_DIRM_OFFSET(bank_num));
 	reg &= BIT(bank_pin_num);
 	if (reg)
 		return GPIOF_OUTPUT;
@@ -369,7 +369,7 @@
 
 static int zynq_gpio_probe(struct udevice *dev)
 {
-	struct zynq_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct zynq_gpio_platdata *plat = dev_get_platdata(dev);
 	struct gpio_dev_priv *uc_priv = dev_get_uclass_priv(dev);
 	const void *label_ptr;
 
@@ -382,19 +382,19 @@
 		uc_priv->bank_name = dev->name;
 	}
 
-	if (platdata->p_data)
-		uc_priv->gpio_count = platdata->p_data->ngpio;
+	if (plat->p_data)
+		uc_priv->gpio_count = plat->p_data->ngpio;
 
 	return 0;
 }
 
 static int zynq_gpio_ofdata_to_platdata(struct udevice *dev)
 {
-	struct zynq_gpio_platdata *platdata = dev_get_platdata(dev);
+	struct zynq_gpio_platdata *plat = dev_get_platdata(dev);
 
-	platdata->base = (phys_addr_t)dev_read_addr(dev);
+	plat->base = (phys_addr_t)dev_read_addr(dev);
 
-	platdata->p_data =
+	plat->p_data =
 		(struct zynq_platform_data *)dev_get_driver_data(dev);
 
 	return 0;
@@ -407,5 +407,5 @@
 	.of_match = zynq_gpio_ids,
 	.ofdata_to_platdata = zynq_gpio_ofdata_to_platdata,
 	.probe	= zynq_gpio_probe,
-	.platdata_auto	= sizeof(struct zynq_gpio_platdata),
+	.plat_auto	= sizeof(struct zynq_gpio_platdata),
 };
